

** Author: Marzia Oceno
** Title: "How Social Desirability Bias Impacts the Expression of Emotions"
** Journal: Political Science Research and Methods
** This file recreates the following from the paper:

*******************************ANES 2012*****************************************

clear 
set more off
use "anes_timeseries_2012.dta"

*********************
** Figure 1 -- 2012 **
*********************

cibar anger [aweight=weight_full], over(web partyid_2cat) graphopts(title("Anger") ytitle("Mean Anger toward Out-Party Cand.") scheme(plotplain) name(anger12, replace))
cibar fear [aweight=weight_full], over(web partyid_2cat) graphopts(title("Fear") ytitle("Mean Fear toward Out-Party Cand.")  scheme(plotplain) name(fear12, replace))
cibar hopeful [aweight=weight_full], over(web partyid_2cat) graphopts(title("Hope") ytitle("Mean Hope toward In-Party Candid.")  scheme(plotplain) name(hope12, replace))
cibar proud [aweight=weight_full], over(web partyid_2cat) graphopts(title("Pride") ytitle("Mean Pride toward In-Party Candid.")  scheme(plotplain) name(pride12, replace))

graph combine anger12 fear12 hope12 pride12, scheme(plotplain) xcommon ycommon col(2)


*********************
** Figure 3 -- 2012 **
*********************

svyset [pweight=weight_full], strata(strata_full) psu(psu_full)

svy: reg anger web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store angryDe
svy: reg anger web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store angryRe
coefplot (angryDe) || (angryRe), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Anger toward Out-Party Candidate") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(angerplot12)

svy: reg fear web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store afraidDe
svy: reg fear web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store afraidRe
coefplot (afraidDe) || (afraidRe), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Fear toward Out-Party Candidate") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(fearplot12)

svy: reg hopeful web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store hopefulDe
svy: reg hopeful web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store hopefulRe
coefplot (hopefulDe) || (hopefulRe), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Hope toward In-Party Candidate") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(hopeplot12)

svy: reg proud web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store proudDe
svy: reg proud web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store proudRe
coefplot (proudDe) || (proudRe), scheme(plottig) legend(off) drop(?cons ageN campaignint polint polknow education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Pride toward In-Party Candidate") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(prideplot12)

graph combine angerplot12 fearplot12 hopeplot12 prideplot12, scheme(plottig) xcommon ycommon col(2)


*********************
** Figure 5 -- 2012 **
*********************

svy: logit persuade c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(anger) at(web=(0 1)) saving("file1D")
svy: logit rally c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(anger) at(web=(0 1)) saving("file2D")
svy: logit button c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(anger) at(web=(0 1)) saving("file3D")
svy: logit volunteer c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(anger) at(web=(0 1)) saving("file4D")
svy: logit donation c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(anger) at(web=(0 1)) saving("file5D")

combomarginsplot "file5D" "file4D" "file3D" "file2D" "file1D", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Anger by Mode among Dems") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(anger12Dem)

svy: logit persuade c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
margins, dydx(anger) at(web=(0 1)) saving("file1R")
svy: logit rally c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
margins, dydx(anger) at(web=(0 1)) saving("file2R")
svy: logit button c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(anger) at(web=(0 1)) saving("file3R")
svy: logit volunteer c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(anger) at(web=(0 1)) saving("file4R")
svy: logit donation c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(anger) at(web=(0 1)) saving("file5R")

combomarginsplot "file5R" "file4R" "file3R" "file2R" "file1R", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Anger by Mode among Reps") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(anger12Rep)


svy: logit persuade c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(fear) at(web=(0 1)) saving("file6D")
svy: logit rally c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(fear) at(web=(0 1)) saving("file7D")
svy: logit button c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(fear) at(web=(0 1)) saving("file8D")
svy: logit volunteer c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(fear) at(web=(0 1)) saving("file9D")
svy: logit donation c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(fear) at(web=(0 1)) saving("file10D")

combomarginsplot "file10D" "file9D" "file8D" "file7D" "file6D", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Fear by Mode among Dems") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(fear12Dem)

svy: logit persuade c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
margins, dydx(fear) at(web=(0 1)) saving("file6R")
svy: logit rally c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
margins, dydx(fear) at(web=(0 1)) saving("file7R")
svy: logit button c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(fear) at(web=(0 1)) saving("file8R")
svy: logit volunteer c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(fear) at(web=(0 1)) saving("file9R")
svy: logit donation c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(fear) at(web=(0 1)) saving("file10R")

combomarginsplot "file10R" "file9R" "file8R" "file7R" "file6R", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Fear by Mode among Reps") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(fear12Rep)


svy: logit persuade c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(hopeful) at(web=(0 1)) saving("file11D")
svy: logit rally c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(hopeful) at(web=(0 1)) saving("file12D")
svy: logit button c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(hopeful) at(web=(0 1)) saving("file13D")
svy: logit volunteer c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(hopeful) at(web=(0 1)) saving("file14D")
svy: logit donation c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(hopeful) at(web=(0 1)) saving("file15D")

combomarginsplot "file15D" "file14D" "file13D" "file12D" "file11D", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Hope by Mode among Dems") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(hope12Dem)

svy: logit persuade c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(hopeful) at(web=(0 1)) saving("file11R")
svy: logit rally c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
margins, dydx(hopeful) at(web=(0 1)) saving("file12R")
svy: logit button c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(hopeful) at(web=(0 1)) saving("file13R")
svy: logit volunteer c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(hopeful) at(web=(0 1)) saving("file14R")
svy: logit donation c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(hopeful) at(web=(0 1)) saving("file15R")

combomarginsplot "file15R" "file14R" "file13R" "file12R" "file11R", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Hope by Mode among Reps") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(hope12Rep)


svy: logit persuade c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(proud) at(web=(0 1)) saving("file16D")
svy: logit rally c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(proud) at(web=(0 1)) saving("file17D")
svy: logit button c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(proud) at(web=(0 1)) saving("file18D")
svy: logit volunteer c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(proud) at(web=(0 1)) saving("file19D")
svy: logit donation c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(proud) at(web=(0 1)) saving("file20D")

combomarginsplot "file20D" "file19D" "file18D" "file17D" "file16D", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Pride by Mode among Dems") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(pride12Dem)

svy: logit persuade c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(proud) at(web=(0 1)) saving("file16R")
svy: logit rally c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(proud) at(web=(0 1)) saving("file17R")
svy: logit button c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(proud) at(web=(0 1)) saving("file18R")
svy: logit volunteer c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(proud) at(web=(0 1)) saving("file19R")
svy: logit donation c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(proud) at(web=(0 1)) saving("file20R")

combomarginsplot "file20R" "file19R" "file18R" "file17R" "file16R", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Pride by Mode among Reps") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(pride12Rep)


grc1leg anger12Dem anger12Rep fear12Dem fear12Rep hope12Dem hope12Rep pride12Dem pride12Rep, scheme(plottig) xcommon ycommon col(2) imargin(small)


*********************************APPENDIX****************************************

*********************
** Table B1 -- 2012 **
*********************

svy: reg anger web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
outreg2 using tabD12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Anger toward Out-Party Candidate") append
svy: reg fear web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
outreg2 using tabD12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Fear toward Out-Party Candidate") append
svy: reg hopeful web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
outreg2 using tabD12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Hope toward In-Party Candidate") append
svy: reg proud web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
outreg2 using tabD12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Pride toward In-Party Candidate") append

*********************
** Table B2 -- 2012 **
*********************

svy: reg anger web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabR12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Anger toward Out-Party Candidate") append
svy: reg fear web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabR12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Fear toward Out-Party Candidate") append
svy: reg hopeful web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabR12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Hope toward In-Party Candidate") append
svy: reg proud web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabR12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Pride toward In-Party Candidate") append

*********************
** Table B5 -- 2012 **
*********************

svy: logit persuade c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemanger12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemanger12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemanger12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemanger12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donation c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemanger12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B6 -- 2012 **
*********************

svy: logit persuade c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabRepanger12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabRepanger12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepanger12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepanger12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donation c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepanger12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B7 -- 2012 **
*********************

svy: logit persuade c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemfear12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemfear12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemfear12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemfear12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donation c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemfear12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B8 -- 2012 **
*********************

svy: logit persuade c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabRepfear12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabRepfear12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepfear12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepfear12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donation c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepfear12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B9 -- 2012 **
*********************

svy: logit persuade c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemhope12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemhope12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemhope12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemhope12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donation c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemhope12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B10 -- 2012 **
*********************

svy: logit persuade c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRephope12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabRephope12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRephope12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRephope12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donation c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRephope12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B11 -- 2012 **
*********************

svy: logit persuade c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDempride12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDempride12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDempride12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDempride12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donation c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDempride12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B12 -- 2012 **
*********************

svy: logit persuade c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabReppride12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabReppride12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabReppride12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabReppride12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donation c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabReppride12.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Figure C1 -- 2012 **
*********************

svy: reg angrycandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store angryDeavg
svy: reg angrycandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store angryReavg
coefplot (angryDeavg) || (angryReavg), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Anger toward Presidential Candidates") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(angeravg12)

svy: reg afraidcandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store afraidDeavg
svy: reg afraidcandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store afraidReavg
coefplot (afraidDeavg) || (afraidReavg), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Fear toward Presidential Candidates") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(fearavg12)

svy: reg hopecandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store hopefulDeavg
svy: reg hopecandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store hopefulReavg
coefplot (hopefulDeavg) || (hopefulReavg), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Hope toward Presidential Candidates") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(hopeavg12)

svy: reg pridecandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store proudDeavg
svy: reg pridecandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store proudReavg
coefplot (proudDeavg) || (proudReavg), scheme(plottig) legend(off) drop(?cons ageN campaignint polint polknow education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Pride toward Presidential Candidates") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(prideavg12)

graph combine angeravg12 fearavg12 hopeavg12 prideavg12, scheme(plottig) xcommon ycommon col(2)




*******************************ANES 2016*****************************************

clear 
set more off
use "anes_timeseries_2016.dta"

*********************
** Figure 2 -- 2016 **
*********************

cibar anger [aweight=V160101], over(web partyid_2cat) graphopts(title("Anger") ytitle("Mean Anger toward Out-Party Cand.") scheme(plotplain) name(anger16, replace))
cibar fear [aweight=V160101], over(web partyid_2cat) graphopts(title("Fear") ytitle("Mean Fear toward Out-Party Cand.")  scheme(plotplain) name(fear16, replace))
cibar hopeful [aweight=V160101], over(web partyid_2cat) graphopts(title("Hope") ytitle("Mean Hope toward In-Party Candid.")  scheme(plotplain) name(hope16, replace))
cibar proud [aweight=V160101], over(web partyid_2cat) graphopts(title("Pride") ytitle("Mean Pride toward In-Party Candid.")  scheme(plotplain) name(pride16, replace))

graph combine anger16 fear16 hope16 pride16, scheme(plotplain) xcommon ycommon col(2)


*********************
** Figure 4 -- 2016 **
*********************

svyset [pweight=V160101]

svy: reg anger web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store angryD
svy: reg anger web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store angryR
coefplot (angryD) || (angryR), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Anger toward Out-Party Candidate") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(angerplot16)

svy: reg fear web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store afraidD
svy: reg fear web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store afraidR
coefplot (afraidD) || (afraidR), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Fear toward Out-Party Candidate") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(fearplot16)

svy: reg hopeful web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store hopefulD
svy: reg hopeful web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store hopefulR
coefplot (hopefulD) || (hopefulR), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Hope toward In-Party Candidate") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(hopeplot16)

svy: reg proud web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store proudD
svy: reg proud web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store proudR
coefplot (proudD) || (proudR), scheme(plottig) legend(off) drop(?cons ageN campaignint polint polknow education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Pride toward In-Party Candidate") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(prideplot16)

graph combine angerplot16 fearplot16 hopeplot16 prideplot16, scheme(plottig) xcommon ycommon col(2)


*********************
** Figure 6 -- 2016 **
*********************

svyset [pweight=V160102]

svy: logit persuade c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(anger) at(web=(0 1)) saving("file1D")
svy: logit rally c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(anger) at(web=(0 1)) saving("file2D")
svy: logit button c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(anger) at(web=(0 1)) saving("file3D")
svy: logit volunteer c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(anger) at(web=(0 1)) saving("file4D")
svy: logit donatecand c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(anger) at(web=(0 1)) saving("file5D")

combomarginsplot "file5D" "file4D" "file3D" "file2D" "file1D", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Anger by Mode among Dems") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(anger16Dem)

svy: logit persuade c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
margins, dydx(anger) at(web=(0 1)) saving("file1R")
svy: logit rally c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
margins, dydx(anger) at(web=(0 1)) saving("file2R")
svy: logit button c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(anger) at(web=(0 1)) saving("file3R")
svy: logit volunteer c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(anger) at(web=(0 1)) saving("file4R")
svy: logit donatecand c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(anger) at(web=(0 1)) saving("file5R")

combomarginsplot "file5R" "file4R" "file3R" "file2R" "file1R", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Anger by Mode among Reps") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(anger16Rep)


svy: logit persuade c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(fear) at(web=(0 1)) saving("file6D")
svy: logit rally c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(fear) at(web=(0 1)) saving("file7D")
svy: logit button c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(fear) at(web=(0 1)) saving("file8D")
svy: logit volunteer c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(fear) at(web=(0 1)) saving("file9D")
svy: logit donatecand c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(fear) at(web=(0 1)) saving("file10D")

combomarginsplot "file10D" "file9D" "file8D" "file7D" "file6D", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Fear by Mode among Dems") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(fear16Dem)

svy: logit persuade c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
margins, dydx(fear) at(web=(0 1)) saving("file6R")
svy: logit rally c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
margins, dydx(fear) at(web=(0 1)) saving("file7R")
svy: logit button c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(fear) at(web=(0 1)) saving("file8R")
svy: logit volunteer c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(fear) at(web=(0 1)) saving("file9R")
svy: logit donatecand c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(fear) at(web=(0 1)) saving("file10R")

combomarginsplot "file10R" "file9R" "file8R" "file7R" "file6R", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Fear by Mode among Reps") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(fear16Rep)


svy: logit persuade c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(hopeful) at(web=(0 1)) saving("file11D")
svy: logit rally c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(hopeful) at(web=(0 1)) saving("file12D")
svy: logit button c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(hopeful) at(web=(0 1)) saving("file13D")
svy: logit volunteer c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(hopeful) at(web=(0 1)) saving("file14D")
svy: logit donatecand c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(hopeful) at(web=(0 1)) saving("file15D")

combomarginsplot "file15D" "file14D" "file13D" "file12D" "file11D", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Hope by Mode among Dems") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(hope16Dem)

svy: logit persuade c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(hopeful) at(web=(0 1)) saving("file11R")
svy: logit rally c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
margins, dydx(hopeful) at(web=(0 1)) saving("file12R")
svy: logit button c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(hopeful) at(web=(0 1)) saving("file13R")
svy: logit volunteer c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(hopeful) at(web=(0 1)) saving("file14R")
svy: logit donatecand c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(hopeful) at(web=(0 1)) saving("file15R")

combomarginsplot "file15R" "file14R" "file13R" "file12R" "file11R", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Hope by Mode among Reps") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(hope16Rep)


svy: logit persuade c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(proud) at(web=(0 1)) saving("file16D")
svy: logit rally c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(proud) at(web=(0 1)) saving("file17D")
svy: logit button c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(proud) at(web=(0 1)) saving("file18D")
svy: logit volunteer c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(proud) at(web=(0 1)) saving("file19D")
svy: logit donatecand c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
margins, dydx(proud) at(web=(0 1)) saving("file20D")

combomarginsplot "file20D" "file19D" "file18D" "file17D" "file16D", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Pride by Mode among Dems") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(pride16Dem)

svy: logit persuade c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(proud) at(web=(0 1)) saving("file16R")
svy: logit rally c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(proud) at(web=(0 1)) saving("file17R")
svy: logit button c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(proud) at(web=(0 1)) saving("file18R")
svy: logit volunteer c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(proud) at(web=(0 1)) saving("file19R")
svy: logit donatecand c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
margins, dydx(proud) at(web=(0 1)) saving("file20R")

combomarginsplot "file20R" "file19R" "file18R" "file17R" "file16R", labels("Donate" "Volunteer" "Display sign" "Attend rally" "Persuade others") recast(scatter) x(_filenumber) horizontal scheme(plottig) ytitle("") xline(0, lc(red)) xtitle("Marginal Effect of Pride by Mode among Reps") title("") legend(pos(6) row(1)) xsize(8) ysize(6) xlabel(-.6(.2).6) plot1opts(mcolor(white) mlcolor(black) msymbol(D)) ci1opts(msize(tiny)) plot2opts(mcolor(black) mlcolor(black) msymbol(D)) ci2opts(msize(tiny) col(black)) offset(0.25) xline(-1 1, lc(white) lp(solid)) name(pride16Rep)


grc1leg anger16Dem anger16Rep fear16Dem fear16Rep hope16Dem hope16Rep pride16Dem pride16Rep, scheme(plottig) xcommon ycommon col(2) imargin(small)


*********************************APPENDIX****************************************

*********************
** Table B3 -- 2016 **
*********************

svyset [pweight=V160101]

svy: reg anger web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
outreg2 using tabD16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Anger toward Out-Party Candidate") append
svy: reg fear web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
outreg2 using tabD16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Fear toward Out-Party Candidate") append
svy: reg hopeful web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
outreg2 using tabD16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Hope toward In-Party Candidate") append
svy: reg proud web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
outreg2 using tabD16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Pride toward In-Party Candidate") append

*********************
** Table B4 -- 2016 **
*********************

svy: reg anger web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabR16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Anger toward Out-Party Candidate") append
svy: reg fear web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabR16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Fear toward Out-Party Candidate") append
svy: reg hopeful web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabR16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Hope toward In-Party Candidate") append
svy: reg proud web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabR16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) title("DV: Pride toward In-Party Candidate") append

*********************
** Table B13 -- 2016 **
*********************

svyset [pweight=V160102]

svy: logit persuade c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemanger16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemanger16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemanger16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemanger16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donatecand c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemanger16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B14 -- 2016 **
*********************

svy: logit persuade c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabRepanger16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabRepanger16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepanger16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepanger16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donatecand c.anger##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepanger16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B15 -- 2016 **
*********************

svy: logit persuade c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemfear16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemfear16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemfear16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemfear16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donatecand c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemfear16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B16 -- 2016 **
*********************

svy: logit persuade c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabRepfear16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabRepfear16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepfear16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepfear16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donatecand c.fear##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRepfear16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B17 -- 2016 **
*********************

svy: logit persuade c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemhope16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemhope16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemhope16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemhope16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donatecand c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDemhope16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B18 -- 2016 **
*********************

svy: logit persuade c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRephope16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
outreg2 using tabRephope16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRephope16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRephope16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donatecand c.hopeful##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabRephope16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B19 -- 2016 **
*********************

svy: logit persuade c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDempride16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDempride16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDempride16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDempride16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donatecand c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0 
outreg2 using tabDempride16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Table B20 -- 2016 **
*********************

svy: logit persuade c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabReppride16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit rally c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabReppride16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit button c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabReppride16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit volunteer c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabReppride16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append
svy: logit donatecand c.proud##i.web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1 
outreg2 using tabReppride16.doc, paren(se) bdec(2) sdec(2) alpha(.001, .01, .05) symbol(***,**,*) append

*********************
** Figure C2 -- 2016 **
*********************

svyset [pweight=V160101]

svy: reg angrycandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store angryDavg
svy: reg angrycandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store angryRavg
coefplot (angryDavg) || (angryRavg), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Anger toward Presidential Candidates") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(angeravg16)

svy: reg afraidcandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store afraidDavg
svy: reg afraidcandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store afraidRavg
coefplot (afraidDavg) || (afraidRavg), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Fear toward Presidential Candidates") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(fearavg16)

svy: reg hopecandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store hopefulDavg
svy: reg hopecandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store hopefulRavg
coefplot (hopefulDavg) || (hopefulRavg), scheme(plottig) legend(off) drop(?cons campaignint polint polknow ageN education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Hope toward Presidential Candidates") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(hopeavg16)

svy: reg pridecandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==0
estimates store proudDavg
svy: reg pridecandavg web campaignint polint polknow gender White latinx ageN education income_norm01 if partyid_2cat==1
estimates store proudRavg
coefplot (proudDavg) || (proudRavg), scheme(plottig) legend(off) drop(?cons ageN campaignint polint polknow education income_norm01) xlabel(-.2 "-.2" -.1 "-.1" 0 "0" .1 ".1" .2 ".2") xline(0) xtitle("Pride toward Presidential Candidates") mlabel format(%9.3f) mlabsize(medsmall) mlabposition(12) name(prideavg16)

graph combine angeravg16 fearavg16 hopeavg16 prideavg16, scheme(plottig) xcommon ycommon col(2)
